package com.iknow.activity;

import android.app.Activity;
import android.app.ProgressDialog;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.webkit.WebChromeClient;
import android.webkit.WebSettings;
import android.webkit.WebSettings.LayoutAlgorithm;
import android.webkit.WebView;
import android.widget.Button;
import android.widget.TextView;

public class AuthorizationWeiboActivity extends Activity
{
  private Button mBackButton;
  private ProgressDialog mProgressDialog;
  private TextView mTitleText;
  private WebView mWebView;

  private void initView()
  {
    this.mBackButton = ((Button)findViewById(2131296342));
    this.mBackButton.setOnClickListener(new View.OnClickListener(this)
    {
      public void onClick()
      {
        this.this$0.finish();
      }
    });
    findViewById(2131296344).setVisibility(8);
    this.mTitleText = ((TextView)findViewById(2131296343));
    this.mTitleText.setText("微博授权");
    this.mWebView = ((WebView)findViewById(2131296270));
    this.mWebView.getSettings().setJavaScriptEnabled(true);
    this.mWebView.getSettings().setSupportZoom(true);
    this.mWebView.getSettings().setBuiltInZoomControls(true);
    this.mWebView.getSettings().setLayoutAlgorithm(WebSettings.LayoutAlgorithm.NARROW_COLUMNS);
    this.mWebView.setWebChromeClient(new WebChromeClient(this)
    {
      public void onProgressChanged(, int paramInt)
      {
        AuthorizationWeiboActivity.access$0(this.this$0, paramInt);
      }
    });
    String str = getIntent().getData().toString();
    this.mWebView.loadUrl(str);
  }

  private void showProgress(int paramInt)
  {
    if (this.mProgressDialog == null)
      this.mProgressDialog = new ProgressDialog(this);
    if (10 == paramInt)
    {
      this.mProgressDialog.setMessage("请稍候");
      this.mProgressDialog.show();
    }
    while (true)
    {
      do
        return;
      while (100 != paramInt);
      this.mProgressDialog.dismiss();
      this.mProgressDialog = null;
    }
  }

  protected void onCreate(Bundle paramBundle)
  {
    super.onCreate(paramBundle);
    requestWindowFeature(1);
    setContentView(2130903042);
    initView();
  }

  protected void onDestroy()
  {
    super.onDestroy();
  }
}